IndexOf Method (T, Int32, Int32)

Wintellect PowerCollections

Collapse imageExpand ImageCollapseAll imageExpandAll imageDropDown imageDropDownHover imageCopy imageCopyHover image
[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

Finds the index of the first item, in the range of count items starting from index, that is equal to item.

Namespace: Wintellect.PowerCollections
Assembly:  PowerCollections (in PowerCollections.dll)

Syntax

C#
public virtual int IndexOf(
	T item,
	int index,
	int count
)
Visual Basic (Declaration)
Public Overridable Function IndexOf ( _
	item As T, _
	index As Integer, _
	count As Integer _
) As Integer
Visual C++
public:
virtual int IndexOf (
	T item, 
	int index, 
	int count
)

Parameters

item
T
The item to search fror.
index
Int32
The starting index of the range to check.
count
Int32
The number of items in range to check.

Return Value

The index of the first item in the given range that that is equal to item. If no item is equal to item, -1 is returned.

Remarks

The default implementation of equality for type T is used in the search. This is the equality defined by IComparable<T> or object.Equals.

See Also